class MyArray1 <T> {
    //public T[] ts1 = new T[2];//这样写不被允许
    public T[] ts2 = (T[]) new Object[2];

    public Object[]  ts3 = new Object[2];

}

public class Test4 {
    public static void main(String[] args) {
        try {
            System.out.println(5/0);
        } catch (ArithmeticException e) {
            System.out.println("算数异常");
        } catch (Exception e) {
            System.out.println("异常");
        }
    }
}
